package com.ayoka.bean;

import java.io.Serializable;
import java.util.List;

/**
 * Created by jinchunping on 2018/5/8.
 */

public class CourseAssignmentBean implements Serializable {
    public static final int ASSIGNMENT_TRAINING = 3;
    public static final int ASSIGNMENT_APPRECIATE = 4;
    public static final int ASSIGNMENT_ADMIXTURE = 5;
    public static final int ASSIGNMENT_VIDEO = 6;

    public static final int FILL = 0;
    public static final int SINGLE_CHOICE = 1;
    public static final int MULTI_CHOICE = 2;
    public static final int GRADE = 3;
    public static final int NO_OPERATION = 4;

    public int ID;
    public int CourseID;
    public int ItemID;
    public int AssignmentType;
    public String Title;
    public String Descp;
    public String VideoUrl;
    public String ImgUrl;
    public List<QuestionBean> Questions;
    public List<OptionBean> Options;
    public List<VideoQuestionBean> VideoQuestions;
    public RelaxingExerciseBean RelaxingExercise;

    public static class QuestionBean implements Serializable {
        public int ID;
        public int AssignmentID;
        public String Question;
        public int QuestionType;
        public List<OptionBean> Options;

        public RequestAdmixtureAssignmentBean AdmixtureAnswer;
    }

    public static class OptionBean implements Serializable {
        public int Index;
        public String Option;
        public boolean isSelected;
    }

    public static class VideoQuestionBean implements Serializable {
        public int ID;
        public int AssignmentID;
        public String VideoUrl;
        public String ImgUrl;
        public String Question;
        public int QuestionType;
        public String CreateDate;
        public boolean isSelected;
        public String answer;
        public long duration;
    }

    public static class RequestAdmixtureAssignmentBean implements Serializable {
        public int QuestionID;
        public String WordAnswer;
        public List<OptionAnswerBean> OptionAnswer;
        public List<ScoreItemAnswerBean> ScoreItemAnswer;
    }

    public static class OptionAnswerBean implements Serializable {
        public int Index;

        public OptionAnswerBean(int index) {
            Index = index;
        }
    }

    public static class ScoreItemAnswerBean implements Serializable {
        public String Name;
        public int Score;

        public ScoreItemAnswerBean(String name, int score) {
            Name = name;
            Score = score;
        }
    }

    public static class RequestCourseAssignmentNewBean extends RequestBase{
        public int CourseID;
        public int TaskID;
        public int AssignmentID;
        public int ItemID;
        public Object Result;
    }

    public static class RelaxingExerciseBean implements Serializable {
        public int ID;
        public int MediaType;
        public String TxtContent;
        public String MediaUrl;
        public String Thumbnail;
        public String CreateDate;
    }

}
